VERSION 5.00
Object = "{3B7C8863-D78F-101B-B9B5-04021C009402}#1.2#0"; "RICHTX32.OCX"
Begin VB.Form frmTicTacToe 
   BackColor       =   &H00000000&
   BorderStyle     =   1  'Fixed Single
   Caption         =   "VectorNet Bot | Tic-Tac-Toe"
   ClientHeight    =   4305
   ClientLeft      =   45
   ClientTop       =   435
   ClientWidth     =   8295
   Icon            =   "frmTicTacToe.frx":0000
   LinkTopic       =   "Form1"
   MaxButton       =   0   'False
   MinButton       =   0   'False
   ScaleHeight     =   4305
   ScaleWidth      =   8295
   StartUpPosition =   3  'Windows Default
   Begin VB.ComboBox cmbPlayers 
      BackColor       =   &H00000000&
      ForeColor       =   &H0000FFFF&
      Height          =   315
      Left            =   6120
      TabIndex        =   27
      Text            =   "cmbPlayers"
      Top             =   1920
      Width           =   2055
   End
   Begin VB.Frame Frame2 
      BackColor       =   &H00000000&
      Caption         =   "Tic Tac Toe (Information)"
      ForeColor       =   &H00FFFF00&
      Height          =   1890
      Left            =   120
      TabIndex        =   22
      Top             =   2325
      Width           =   5895
      Begin VB.Label Label7 
         BackColor       =   &H00000000&
         Caption         =   "Click the Quit Game button located above to ensure a full exit of the current session you are in with the selected player."
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   9.75
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FF00&
         Height          =   1215
         Left            =   3120
         TabIndex        =   26
         Top             =   600
         Width           =   2655
      End
      Begin VB.Label Label6 
         BackColor       =   &H00000000&
         Caption         =   "Ending a game:"
         ForeColor       =   &H0000FFFF&
         Height          =   255
         Left            =   3120
         TabIndex        =   25
         Top             =   360
         Width           =   1695
      End
      Begin VB.Label Label2 
         BackColor       =   &H00000000&
         Caption         =   "Starting a game:"
         ForeColor       =   &H0000FFFF&
         Height          =   255
         Left            =   240
         TabIndex        =   24
         Top             =   360
         Width           =   1695
      End
      Begin VB.Label Label1 
         BackColor       =   &H00000000&
         Caption         =   "Select a Player from the drop-down list located on the left side of the window. Then click Play Against"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   9.75
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FF00&
         Height          =   975
         Left            =   240
         TabIndex        =   23
         Top             =   600
         Width           =   2775
      End
   End
   Begin VB.CommandButton btnPlayAgain 
      Caption         =   "Play Again"
      Enabled         =   0   'False
      Height          =   315
      Left            =   120
      TabIndex        =   19
      Top             =   1920
      Width           =   3375
   End
   Begin VB.Timer tmrContinue 
      Enabled         =   0   'False
      Interval        =   2000
      Left            =   4920
      Top             =   240
   End
   Begin VB.Timer tmrCheckCompat 
      Enabled         =   0   'False
      Interval        =   5000
      Left            =   5400
      Top             =   240
   End
   Begin VB.CommandButton cmdQuit 
      Caption         =   "Quit Game"
      Height          =   315
      Left            =   4800
      TabIndex        =   17
      Top             =   1920
      Width           =   1215
   End
   Begin VB.CommandButton btnRequest 
      Caption         =   "Play Against"
      Height          =   315
      Left            =   3600
      TabIndex        =   16
      Top             =   1920
      Width           =   1095
   End
   Begin VB.Frame Frame1 
      BackColor       =   &H00000000&
      Caption         =   "Game Statistics"
      ForeColor       =   &H00FFFF00&
      Height          =   1905
      Left            =   6120
      TabIndex        =   9
      Top             =   2310
      Width           =   2055
      Begin VB.Line Line1 
         BorderColor     =   &H00FFFFFF&
         X1              =   120
         X2              =   1920
         Y1              =   1440
         Y2              =   1440
      End
      Begin VB.Label lbl6 
         BackColor       =   &H00000000&
         Caption         =   "Total:"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   8.25
            Charset         =   0
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H00FFFFFF&
         Height          =   255
         Left            =   120
         TabIndex        =   21
         Top             =   1560
         Width           =   1095
      End
      Begin VB.Label lblGamesPlayed 
         BackColor       =   &H00000000&
         Caption         =   "0"
         ForeColor       =   &H00FFFFFF&
         Height          =   255
         Left            =   1320
         TabIndex        =   20
         Top             =   1560
         Width           =   615
      End
      Begin VB.Label lblCatsGames 
         BackColor       =   &H00000000&
         Caption         =   "0"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   9.75
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H00FFFFFF&
         Height          =   255
         Left            =   1320
         TabIndex        =   15
         Top             =   1080
         Width           =   615
      End
      Begin VB.Label lblWins 
         BackColor       =   &H00000000&
         Caption         =   "0"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   9.75
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H00FFFFFF&
         Height          =   255
         Left            =   1320
         TabIndex        =   14
         Top             =   360
         Width           =   615
      End
      Begin VB.Label lblLosses 
         BackColor       =   &H00000000&
         Caption         =   "0"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   9.75
            Charset         =   0
            Weight          =   400
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H00FFFFFF&
         Height          =   255
         Left            =   1320
         TabIndex        =   13
         Top             =   720
         Width           =   615
      End
      Begin VB.Label Label5 
         BackColor       =   &H00000000&
         Caption         =   "Cat Games:"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   8.25
            Charset         =   0
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FFFF&
         Height          =   255
         Left            =   120
         TabIndex        =   12
         Top             =   1080
         Width           =   1095
      End
      Begin VB.Label Label4 
         BackColor       =   &H00000000&
         Caption         =   "Wins:"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   8.25
            Charset         =   0
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H0000FF00&
         Height          =   255
         Left            =   120
         TabIndex        =   11
         Top             =   360
         Width           =   495
      End
      Begin VB.Label Label3 
         BackColor       =   &H00000000&
         Caption         =   "Losses:"
         BeginProperty Font 
            Name            =   "MS Sans Serif"
            Size            =   8.25
            Charset         =   0
            Weight          =   700
            Underline       =   0   'False
            Italic          =   0   'False
            Strikethrough   =   0   'False
         EndProperty
         ForeColor       =   &H000000FF&
         Height          =   255
         Left            =   120
         TabIndex        =   10
         Top             =   720
         Width           =   855
      End
   End
   Begin RichTextLib.RichTextBox rtbEvents 
      Height          =   1695
      Left            =   120
      TabIndex        =   18
      Top             =   120
      Width           =   5895
      _ExtentX        =   10398
      _ExtentY        =   2990
      _Version        =   393217
      BackColor       =   0
      Enabled         =   -1  'True
      ReadOnly        =   -1  'True
      ScrollBars      =   3
      TextRTF         =   $"frmTicTacToe.frx":0CCA
   End
   Begin VB.Label lblBottomRight 
      Alignment       =   2  'Center
      BackColor       =   &H8000000D&
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   7560
      TabIndex        =   8
      Top             =   1320
      Width           =   615
   End
   Begin VB.Label lblBottom 
      Alignment       =   2  'Center
      BackColor       =   &H8000000D&
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   6840
      TabIndex        =   7
      Top             =   1320
      Width           =   615
   End
   Begin VB.Label lblBottomLeft 
      Alignment       =   2  'Center
      BackColor       =   &H8000000D&
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   6120
      TabIndex        =   6
      Top             =   1320
      Width           =   615
   End
   Begin VB.Label lblRight 
      Alignment       =   2  'Center
      BackColor       =   &H8000000D&
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   7560
      TabIndex        =   5
      Top             =   720
      Width           =   615
   End
   Begin VB.Label lblCenter 
      Alignment       =   2  'Center
      BackColor       =   &H8000000D&
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   6840
      TabIndex        =   4
      Top             =   720
      Width           =   615
   End
   Begin VB.Label lblLeft 
      Alignment       =   2  'Center
      BackColor       =   &H8000000D&
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   6120
      TabIndex        =   3
      Top             =   720
      Width           =   615
   End
   Begin VB.Label lblTopRight 
      Alignment       =   2  'Center
      BackColor       =   &H8000000D&
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   7560
      TabIndex        =   2
      Top             =   120
      Width           =   615
   End
   Begin VB.Label lblTop 
      Alignment       =   2  'Center
      BackColor       =   &H8000000D&
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   6840
      TabIndex        =   1
      Top             =   120
      Width           =   615
   End
   Begin VB.Label lblTopLeft 
      Alignment       =   2  'Center
      BackColor       =   &H8000000D&
      BeginProperty Font 
         Name            =   "MS Sans Serif"
         Size            =   24
         Charset         =   0
         Weight          =   400
         Underline       =   0   'False
         Italic          =   0   'False
         Strikethrough   =   0   'False
      EndProperty
      Height          =   495
      Left            =   6120
      TabIndex        =   0
      Top             =   120
      Width           =   615
   End
End
Attribute VB_Name = "frmTicTacToe"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim playSymbol As String
Dim strX As String
Dim strO As String
Dim numMoves As Integer
Dim canMove As Boolean
Dim isCompatible As Boolean
Dim lastOutcome As String
Dim hasWon As Boolean
Dim numCats As Long
Dim numWins As Long
Dim numLosses As Long
Dim oppSymbol As String
Dim dicMoves As Object
Dim gameInProg As Boolean

Private Sub btnPlayAgain_Click()
  If frmChat.sckVectorNet.State <> sckConnected Then Exit Sub
  
  Call clearBoard
 
  If hasWon Then
    AddEvent vbCyan, "You were the last to win any game. You may go first."
    canMove = True
  Else
    AddEvent vbCyan, opponent & " was the last to win. They will go first."
  End If
  btnPlayAgain.Enabled = False
  
  sendPacket &H8, "game reset" & Chr$(0) & opponent
End Sub

Private Sub btnRequest_Click()
  If Not frmChat.sckVectorNet.State = sckConnected Then Exit Sub
  
  Call clearBoard
  
  If cmbPlayers.List(cmbPlayers.ListIndex) = vbNullString Then
    AddEvent vbRed, "Your opponent has not been selected!"
    Exit Sub
  End If
  btnRequest.Enabled = False
  opponent = cmbPlayers.List(cmbPlayers.ListIndex)

  AddEvent vbYellow, "Sending initialization to " & opponent & "..."
  sendPacket &H8, "init request" & Chr$(0) & opponent
  tmrCheckCompat.Enabled = True
End Sub

Public Sub handleOutsideEvents(ByVal tttData As String)
  getEvent = Split(tttData, Chr$(0))(0)
  
  Select Case LCase(getEvent)
    Case "init request"
      opponent = Split(tttData, Chr$(0))(1)
      sendPacket &H8, "init response" & Chr$(0) & opponent
    Case "init response"
      tmrCheckCompat.Enabled = False
      AddEvent vbGreen, opponent & " has responded to initialization request."
      AddEvent vbYellow, "Awaiting game request from " & opponent & "..."
      sendPacket &H8, "game request" & Chr$(0) & opponent
      tmrContinue.Enabled = False
    Case "game request"
      opponent = Split(tttData, Chr$(0))(1)
      frmTTTRequest.Show
    Case "game accept"
      gameInProg = True
      AddEvent vbGreen, opponent & " has accepted your request!"
      Me.Caption = "VectorNet Bot | Tic Tac Toe - Game with " & opponent
      AddEvent vbWhite, opponent & " goes first."
    
      determinePlayer = CInt(Rnd * 3)
      Select Case determinePlayer
        Case 0, 2
          playSymbol = "X"
          oppSymbol = "O"
        Case 1, 3
          playSymbol = "O"
          oppSymbol = "X"
      End Select
      sendPacket &H8, "start prepare" & Chr$(0) & opponent & Chr$(0) & playSymbol
      Me.Caption = "VectorNet Bot | Tic Tac Toe - Game with " & opponent
    Case "start prepare"
      gameInProg = True
      btnRequest.Enabled = False
      Me.Caption = "Tic Tac Toe - Game with " & opponent
      AddEvent vbCyan, "A game of Tic-Tac-Toe has been started with " & opponent
      playSymbol = Split(tttData, Chr$(0))(2)
      AddEvent vbWhite, "Play determined. ", vbYellow, "You are playing as ", vbWhite, playSymbol
      AddEvent vbWhite, "You may now move."
      
      If Not frmChat.sckVectorNet.State = sckConnected Then Exit Sub
      queryType = "ticlist"
      sendPacket &H12, vbNullString
      
      If playSymbol = "O" Then
        oppSymbol = "X"
      Else
        oppSymbol = "O"
      End If
      
      canMove = True
      gameInProg = True
    Case "game deny"
      AddEvent vbRed, opponent & " has denied the tic-tac-toe request!"
      btnRequest.Enabled = True
    Case "board move"
      slot = Split(tttData, Chr$(0))(2)
      Call handleTurn(slot, oppSymbol, True)
    Case "game reset"
      AddEvent vbWhite, opponent, vbYellow, " has requested another game of tic tac toe."
      Call clearBoard
      btnPlayAgain.Enabled = False
      
      If lastOutcome = "win" Then
        AddEvent vbWhite, "Since you won the last game, you can move first."
        canMove = True
      Else
        If hasWon Then
          AddEvent vbWhite, "Since you won the last non-cats game, you move first."
          canMove = True
        Else
          AddEvent vbCyan, opponent & " will play first."
        End If
      End If
    Case "game quit"
      MsgBox (opponent & " has quit the game.")
      Unload Me
  End Select
End Sub

Private Sub cmdQuit_Click()
  Unload Me
End Sub

Private Sub Form_Load()
  Me.Left = frmChat.Left + 1800
  Me.Top = frmChat.Top + 1400
  Set dicMoves = CreateObject("Scripting.Dictionary")
  gameInProg = False
  
  AddEvent vbYellow, "This is the Game Status window, Game information will be here."
  AddEvent vbTeal, "Welcome to VectorNet Bot Tic-Tac-Toe v1.2 have fun!"
  
  If Not frmChat.sckVectorNet.State = sckConnected Then
    AddEvent vbRed, "Unable to play, Connect to a Server First!"
  Else
    canMove = False
    requestType = "ticlist"
    sendPacket &H12, vbNullString
    numMoves = 0
    isCompatible = False
  End If
End Sub

Private Sub Form_Unload(Cancel As Integer)
  If Not frmChat.sckVectorNet.State = sckConnected Then Exit Sub
  If opponent = vbNullString Then Exit Sub
  If Not gameInProg Then Exit Sub

  sendPacket &H8, "game quit" & Chr$(0) & opponent
  Unload Me
End Sub

Private Sub lblBottom_Click()
  Call handleTurn(2, playSymbol)
End Sub

Private Sub lblBottomLeft_Click()
  Call handleTurn(1, playSymbol)
End Sub

Private Sub lblBottomRight_Click()
  Call handleTurn(3, playSymbol)
End Sub

Private Sub lblCenter_Click()
  Call handleTurn(5, playSymbol)
End Sub

Private Sub lblLeft_Click()
  Call handleTurn(4, playSymbol)
End Sub

Private Sub lblRight_Click()
  Call handleTurn(6, playSymbol)
End Sub

Private Sub lblTop_Click()
  Call handleTurn(8, playSymbol)
End Sub

Private Sub lblTopLeft_Click()
  Call handleTurn(7, playSymbol)
End Sub

Private Sub lblTopRight_Click()
  Call handleTurn(9, playSymbol)
End Sub

Private Sub handleTurn(ByVal getSlot As Integer, ByVal symbol As String, Optional isOpponent As Boolean = False)
  If dicMoves.Exists(getSlot) Then Exit Sub
  
  If Not canMove And Not isOpponent Then Exit Sub
  
  Dim slot As Integer
  
  slot = CInt(getSlot)
  
  Select Case slot
    Case 1
      movePosition = "bottom left"
    Case 2
      movePosition = "bottom"
    Case 3
      movePosition = "bottom right"
    Case 4
      movePosition = "left"
    Case 5
      movePosition = "center"
    Case 6
      movePosition = "right"
    Case 7
      movePosition = "top left"
    Case 8
      movePosition = "top"
    Case 9
      movePosition = "top right"
  End Select
  
  dicMoves.Item(getSlot) = True
  
  If isOpponent Then
    AddEvent vbYellow, opponent & " moved to the ", vbWhite, movePosition & "."
  Else
    AddEvent vbYellow, user & " moved to the ", vbWhite, movePosition & "."
  End If
  
  Select Case slot
    Case 1:
            If lblBottomLeft.Caption = vbNullString Then
              lblBottomLeft.Caption = symbol
            End If
    Case 2:
            If lblBottom.Caption = vbNullString Then
              lblBottom.Caption = symbol
            End If
    Case 3:
            If lblBottomRight.Caption = vbNullString Then
              lblBottomRight.Caption = symbol
            End If
    Case 4:
            If lblLeft.Caption = vbNullString Then
              lblLeft.Caption = symbol
            End If
    Case 5:
            If lblCenter.Caption = vbNullString Then
              lblCenter.Caption = symbol
            End If
    Case 6:
            If lblRight.Caption = vbNullString Then
              lblRight.Caption = symbol
            End If
    Case 7:
            If lblTopLeft.Caption = vbNullString Then
              lblTopLeft.Caption = symbol
            End If
    Case 8:
            If lblTop.Caption = vbNullString Then
              lblTop.Caption = symbol
            End If
    Case 9:
            If lblTopRight.Caption = vbNullString Then
              lblTopRight.Caption = symbol
            End If
  End Select

  If Not isOpponent Then
    canMove = False
    sendPacket &H8, "board move" & Chr$(0) & opponent & Chr$(0) & slot
  Else
    canMove = True
  End If

  Call evaluateBoard(slot, symbol)
End Sub

Private Sub evaluateBoard(ByVal location As Integer, ByVal symbol As String)
  Dim arrPossible() As Variant, testMoves As String
  
  arrPossible = Array("123", "159", "147", "258", "369", "357", "456", "789")
  
  Select Case symbol
    Case "X"
      strX = strX & CStr(location)
      testMoves = strX
    Case "O"
      strO = strO & CStr(location)
      testMoves = strO
  End Select

  If Len(strX) >= 3 Or Len(strO) >= 3 Then
    countTimes = 0
    For Each combo In arrPossible
      For i = 0 To Len(testMoves) - 1
        getPos = Mid(testMoves, i + 1, 1)
      
        For j = 0 To Len(combo) - 1
          getChar = Mid(combo, j + 1, 1)
          If getPos = getChar Then
            countTimes = countTimes + 1
          End If
        Next j

        If countTimes = 3 Then
          If symbol = playSymbol Then
            AddEvent vbGreen, "Congratulations, you are a winner!"
            Call handleResult("win")
            hasWon = True
            btnRequest.Enabled = True
            btnPlayAgain.Enabled = True
            strX = vbNullString: strO = vbNullString
          Else
            AddEvent vbRed, opponent & " just beat you!"
            Call handleResult("loss")
            hasWon = False
            btnRequest.Enabled = True
            btnPlayAgain.Enabled = True
            strX = vbNullString: strO = vbNullString
          End If
          
          canMove = False
          Exit Sub
        End If
      Next i
      countTimes = 0
    Next
  End If
  numMoves = numMoves + 1
  
  If numMoves = 9 Then
    AddEvent vbYellow, "No one wins this game. It's a cats game!"
    strX = vbNullString: strO = vbNullString
    Call handleResult("cats")
    btnRequest.Enabled = True
    btnPlayAgain.Enabled = True
  End If
End Sub

Public Sub AddEvent(ParamArray saElements() As Variant)
Dim i As Integer, s As String
  With Me.rtbEvents
    .SelStart = 99999
    .SelLength = 0
    .SelColor = vbWhite
    .SelText = "[" & Time & "] "
 
    For i = LBound(saElements) To UBound(saElements) Step 2
      .SelStart = 99999
      .SelLength = 0
      .SelColor = saElements(i)
      .SelText = saElements(i + 1) & Left$(vbCrLf, -2 * CLng((i + 1) = UBound(saElements)))
    Next i
    .SelStart = 99999
    .SelLength = 0
    .SelText = vbNullString
  End With
End Sub

Private Sub handleResult(ByVal endType As String)
  Select Case LCase(endType)
    Case "win"
      numWins = numWins + 1
      lblWins.Caption = numWins
    Case "loss"
      numLosses = numLosses + 1
      lblLosses.Caption = numLosses
    Case "cats"
      numCats = numCats + 1
      lblCatsGames.Caption = numCats
  End Select
  
  If Not frmChat.sckVectorNet.State = sckConnected Then Exit Sub
  queryType = "ticlist"
  sendPacket &H12, vbNullString
  
  lastOutcome = endType
  dicMoves.RemoveAll
  numMoves = 0
  gameInProg = False
  lblGamesPlayed.Caption = numWins + numLosses + numCats
End Sub

Private Sub clearBoard()
  lblTopLeft.Caption = vbNullString
  lblTop.Caption = vbNullString
  lblTopRight.Caption = vbNullString
  lblLeft.Caption = vbNullString
  lblCenter.Caption = vbNullString
  lblRight.Caption = vbNullString
  lblBottomLeft.Caption = vbNullString
  lblBottom.Caption = vbNullString
  lblBottomRight.Caption = vbNullString
End Sub

Private Sub tmrCheckCompat_Timer()
  If Not isCompatible Then
    AddEvent vbRed, "Client does not support tic tac toe!"
    btnRequest.Enabled = True
  End If
  tmrCheckCompat.Enabled = False
End Sub

Public Function addToCombo(ByVal players As String)
  addPlayers = Split(players, ", ")
  cmbPlayers.Clear
  For Each elem In addPlayers
    If Not LCase(remSpecial(elem)) = LCase(user) Then
      frmTicTacToe.cmbPlayers.text = "Select your Opponent!"
      frmTicTacToe.cmbPlayers.AddItem remSpecial(elem)
    End If
  Next
End Function
